package com.oa.admin.service;

import com.baomidou.mybatisplus.plugins.Page;
import com.joneying.common.web.response.Resp;
import com.oa.admin.dto.DepartmentApplyAddDTO;
import com.oa.admin.dto.DepartmentApplyListDTO;
import com.oa.admin.vo.DepartmentApplyByDepartmentIdVO;
import com.oa.admin.vo.DepartmentApplyDetailsVO;
import com.oa.admin.vo.DepartmentApplyListVO;
import com.oa.core.PageResult;
import com.oa.admin.entity.DepartmentApply;
import com.baomidou.mybatisplus.service.IService;
import com.oa.core.exception.BusinessException;
import com.oa.core.exception.DataIsEmptyException;

import java.util.List;

/**
 * <p>
 * 部门活动申请表 服务类
 * </p>
 *
 * @author syb123
 * @since 2019-01-22
 */
public interface IDepartmentApplyService extends IService<DepartmentApply> {
    /**
     * 自定义分页
     * @param pageNum
     * @param pageSize
     * @return
     */
    PageResult<DepartmentApply> findList(Integer pageNum, Integer pageSize);

    List<DepartmentApplyByDepartmentIdVO> findByDepartmentId(String departmentId);

    PageResult<DepartmentApplyListVO> findDepartmentApplyList(DepartmentApplyListDTO departmentApplyListDTO);

    Resp add(DepartmentApplyAddDTO departmentApplyAddDTO) throws BusinessException, DataIsEmptyException;

    DepartmentApplyDetailsVO findDepartmentApplyDetails(String id);

    Resp audit(String id, Integer status) throws DataIsEmptyException;
}
